﻿
namespace 多态
{
    class Calculate
    {
        protected int x { get; set; }
        protected int y { get; set; }
        protected int sum { get; set; }
        protected int subtract { get; set; }
        protected int multiply { get; set; }
        protected double divide { get; set; }

        public virtual void DisplayResult(int X, int Y)
        {
             sum = X + Y;
             subtract = X - Y;
            multiply = X * Y;
            divide = X / Y;
        }
        


    }
}